package org.ruiyichen.guizhou.agr.bean.mode;

import org.ruiyichen.guizhou.agr.imp.HomeMonitorFilter;


public class HomeMonitorModel implements HomeMonitorFilter {

    public String resourceName;
    public String resourceUnit;
    public String stateValue;
    public String resourceIcon;

    //采集设备名称：
    //启动时间：
    //完成时间：
    //规格：
    //班组号：
    //模具号：
    public String macAddress;
    public String createTime;


    @Override
    public String getDrawableRes() {
//        monitorModels.add(new HomeMonitorModel(R.drawable.df_home_shuiwei, "水位", "0.2cm"));
//        monitorModels.add(new HomeMonitorModel(R.drawable.df_home_ph, "PH", "30"));
//        monitorModels.add(new HomeMonitorModel(R.drawable.df_home_ec, "EC", "6%"));
//        monitorModels.add(new HomeMonitorModel(R.drawable.df_home_guang_zhao_du, "光照度", "45000lux"));
//        monitorModels.add(new HomeMonitorModel(R.drawable.df_home_kqsd, "空气湿度", "61.5%"));
//        monitorModels.add(new HomeMonitorModel(R.drawable.df_home_fs, "风速", "2.1m/h"));
/*        int drawableRes;
        if ("水位".equals(resourceName)) {
            drawableRes = R.drawable.df_home_shuiwei;
        } else if ("PH".equals(resourceName) || "空气温度".equals(resourceName)) {
            drawableRes = R.drawable.df_home_ph;
        } else if ("空气湿度".equals(resourceName)) {
            drawableRes = R.drawable.df_home_kqsd;
        } else if ("EC".equals(resourceName) || "土壤湿度".equals(resourceName)) {
            drawableRes = R.drawable.df_home_ec;
        } else if ("光照度".equals(resourceName)) {
            drawableRes = R.drawable.df_home_guang_zhao_du;
        } else if ("风速".equals(resourceName)) {
            drawableRes = R.drawable.df_home_fs;
        } else {
            drawableRes = R.drawable.df_home_shuiwei;
        }*/
        return resourceIcon;
    }

    @Override
    public String getMonitorTip() {
        return resourceName;
    }

    @Override
    public String getMonitorNum() {
        return stateValue + resourceUnit;
    }
}
